/**
  \mainpage
  ETFRoot project, Anyang Normal University && IMP-CAS
  \brief unpack binary data from daq
  \author SUN Yazhou, asia.rabbit@163.com
  \since 2021-10-06
  \date 2021-10-06 last modified
  \attention
  changelog
  <table>
  <tr>  <th>Date         <th>Author      <th>Description                   </tr>
  <tr>  <td>2021-10-06   <td>Asia Sun    <td>file created                  </tr>
  </table>

  \copyright Copyright (c) 2021 Anyang Normal U. && IMP-CAS with LGPLv3 LICENSE
*/

#include <cstdlib>
#include <iostream>
#include <unistd.h>
#include <TString.h>
#include <TStopwatch.h>

#include "FairRunOnline.h"
#include "FairRootFileSink.h"
#include "FairRuntimeDb.h"
#include "FairParRootFileIo.h"

// PXI source header files
#include "ETFPXIOfflineSource.h"
#include "ETFPXIUnpacker.h"
// VME source header files
#include "ETFVMEOfflineSource.h"
#include "ETFUserVMEUnpacker.h"
// Mixed source header files
#include "ETFMixedOfflineSource.h"

#include "ETFUserUnpackTask.h"
#include "ETFMsg.h"

using std::cout;
using std::endl;

// #define PXI
#define VME
// #define MIXED

#ifdef PXI
#include "unpackPXI.C"
#endif
#ifdef VME
#include "unpackVME.C"
#endif
#ifdef MIXED
#include "unpackMixed.C"
#endif

int main(int argc, char **argv){
#ifdef PXI
  unpackPXI();
#endif
#ifdef VME
  unpackVME();
#endif
#ifdef MIXED
  unpackMixed();
#endif

  return 0;
} // end the main function sim
